package userServiceDemo.controller;


import cn.t11.dm.pojo.Dto;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import userServiceDemo.service.DmUserService;

import javax.servlet.http.HttpServletRequest;

/**
 * <p>
 * 用户表 前端控制器
 * </p>
 *
 * @author jobob
 * @since 2020-01-14
 */
@RestController
@RequestMapping("user/api")
public class DmUserController {

        @Autowired
        DmUserService DmUserService;

        //密码登录接口
        @PostMapping("p/login")
        public Dto dologin(String phone, String password,HttpServletRequest request){
                return DmUserService.doLogin(phone, password,request);
        }
}
